package wenjian;
public class Student extends People {
    public Teacher name;
    public Course b;
    public boolean choose;

    public Student(int id, String name, char sex, Teacher t, Course c,boolean choose) {
        super(id, name, sex );
        this.name = t;
        this.b = c;
        this.choose=choose;
    }
    public boolean getAll() {
        return choose;
    }
    public String toString() {
        return "学生编号:" + getId() + "学生姓名:" + getName() + "性别:" + getSex() + "授课老师：" + name.name + this.b ;
    }
}

